<?php

namespace Wantuch\MailerBundle\Form\Type;

use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;

class SubscriberType extends AbstractType
{
    public function buildForm(FormBuilderInterface $builder, array $options)
    {
        $builder
            ->add('name')
            ->add('surname')
            ->add('email')
            ->add('description')
            ->add('active','choice', array(
                'choices'   => array('T' => 'Tak', 'N' => 'Nie'),
                'required'  => true,
                'expanded' => true,
                'multiple' => false
            ))
            ->add('campaign')
            ->add('save', 'submit');
    }

    public function getName()
    {
        return 'subscriber';
    }
}